﻿  <%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<Gman.WebApp.Models.MaterialModel>" %>

  
   <table width="100%" class="GridLista">
    <tr  class="HeaderStyle">
    <th>
         Tipo
        </th>
        <th>
           Familia
        </th>
        <th>
           Sub Familia
        </th>
        <th>
            Categoria
        </th>
        <th>
            Sub Categoria
        </th>
        <th>
            Descripcion
        </th>
        <th>
            Unidad
        </th>
         <th>
            Costo Promedio
        </th>
        <th>
            Ir
        </th>
    </tr>   
    
    <% %>
<% foreach (var item in Model.Materiales)
   { %>
     <tr class="ItemStyle">           
            <td style="width:150px"> <%= Html.Encode(item.TipoMate) %></td>
            <td style="width:150px"> <%= Html.Encode(item.FamiMate) %></td>
            <td style="width:150px"> <%= Html.Encode(item.SubFamiMate) %></td>
            <td style="width:150px"> <%= Html.Encode(item.CatMate) %></td>
            <td style="width:150px"> <%= Html.Encode(item.SubCatMate) %></td>
            <td style="width:500px"> <%= Html.Encode(item.DescMate) %></td>
            <td style="width:100px"> <%= Html.Encode(item.UniMedMate) %></td>
            <td style="width:100px"> <%= Html.Encode(item.CostoPromMate) %></td>
<td style="width:100px">
        <%--<%= Html.ActionLink("Ver", "ObtenerMaterial", new { Model.ID, material = item }, null)%>--%>          
        <a class="ActionLink" href="#" onclick="ObtenerMaterial('<%= item.IDMaterial %>', true)">Ver</a>          
           </td>  
        </tr>
<% } %>      
</table>